<% render_spedific_sidebar render(:partial=>"novel_show_sidebar") %>
<%= render :partial=>"novel_summary", :object=>@novel %>
<%
   if  @novel.is_over
%>
    <h5>该文章结束续写！<%= link_to_open_show @novel %></h5>
<%
   else
%>
    <p><%= link_to_over_show @novel %></p>
<%
   end
%>

<h3> 第 <%=@chapter.sequence%> 回 </h3>
<%= link_to("folk", folk_novel_path(@novel))%>
<%=link_to('edit',novel_chapter_path(@novel,@chapter), :id=>'chapter_edit')%>
<div id="chapter_body">
<p><span id="novel_chapter_title"><%=simple_format @chapter.title || "'not yet'"%></span></p>
<p><span id="novel_chapter_suggest"><%=simple_format @chapter.suggest || "'not yet'"%><span></p>
</div>
<!--Hidden field-->
<div id='chapter_form' style="display:none">
    <%=form_for @chapter, :as=>:chapter, :method=>'put' ,:remote=>true,:url=>novel_chapter_path(@novel,@chapter) do |f| %>
        <%= error_messages_for :fragment -%>
		<table>
		<tr>
			<td>Title</td>
			<td><%= f.text_field :title%></td>
		</tr>
		<tr>
			<td>Suggest:</td>
			<td><%= f.text_area :suggest, :cols=>70, :rows=>8 %></td>
		</tr>
        </br>
		</table>
    <% end %>
</div>
<hr></hr>
<%= render :partial=>"fragments/fragment_form"%>
<hr></hr>
<!-- Display fragments about this chapter -->
<h1>Fragments</h1>
<%= render :partial => "fragments/simple_fragment", :collection => @chapter.fragments , :as=>:fragment%> 